package banmuoi.util;

import org.hibernate.Session;
import org.hibernate.SessionFactory;
import org.hibernate.cfg.AnnotationConfiguration;
import org.hibernate.cfg.Configuration;

public class HibernateUtil {
	static Configuration config = new AnnotationConfiguration().configure();
	static SessionFactory factory = config.buildSessionFactory();
	
	public static Session openSession() {
		Session session = factory.openSession();
		return session;
	}
}
